<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<script>
			var a=new Array(5);
			a[0]="America";
			a[1]="Greece";
			a[2]="Britain";
			a[3]="Canada";
			a[4]="China";
			var b=0;
			for(var i in a){
				var str1=a[i].indexOf("a");
				var str2=a[i].indexOf("A");
				if (str1!=-1||str2!=-1) {
					b++;
				} 
			}
			document.write("共有"+b+"A和a");

//alert(a.length);
//			alert("asdadg");
		</script>
	</head>
	<body>
	</body>
</html>
